package com.light.sys.controller;

import com.light.common.base.PageResult;
import com.light.common.base.ResponseResult;
import com.light.common.base.BaseController;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import com.light.sys.domain.SysUserDO;
import com.light.sys.service.SysUserService;
import com.light.sys.query.SysUserQuery;


/**
 * 
 * @Description: 用户名
 * @author yhr
 * @Version V1.0
 * @date 
 */

@RestController
@RequestMapping("/sys/sysUser")
@Api(tags  =  "用户管理",  description  =  "")
public class SysUserController extends BaseController<SysUserDO, SysUserService>{
	@Autowired
	private SysUserService sysUserService;
	
    @ApiOperation(value="获取列表信息")
    @GetMapping("")
	public ResponseResult<PageResult<SysUserDO>> data(SysUserQuery sysUserQuery){
		//查询列表数据
        PageResult pageResult=new PageResult(sysUserService.data(sysUserQuery)
                ,sysUserService.count(sysUserQuery),sysUserQuery);
        return ResponseResult.success(pageResult);
	}

}
